global.webpackJsonp([ 35 ], {
    "/nNs": function(t, e, n) {
        var i = {
            render: function() {
                var t = this, e = t.$createElement, n = t._self._c || e;
                return n("div", {
                    class: [ "main", "theme-" + t.theme ]
                }, [ n("div", {
                    staticClass: "background-image"
                }, [ "ningboHome" === t.tabBarList[0] ? [ n("image", {
                    staticClass: "ning-top-right",
                    attrs: {
                        src: t.ningTopRight
                    }
                }), t._v(" "), n("image", {
                    staticClass: "ning-bottom-left",
                    attrs: {
                        src: t.ningBottomLeft
                    }
                }) ] : t._e() ], 2), t._v(" "), n("div", {
                    staticClass: "welcome-title"
                }, [ t._v(t._s(t.title[t.tabBarList[0]])) ]), t._v(" "), n("div", {
                    staticClass: "main-title"
                }, [ t._v(t._s("login" === t.page ? "登录/注册" : "填写验证码")) ]), t._v(" "), n("div", {
                    staticClass: "sub-title"
                }, [ n("span", {
                    staticClass: "sub-title__hint"
                }, [ t._v(t._s("login" === t.page ? t.welcomeTitle[t.tabBarList[0]] : "已发送验证码至" + t.phoneNum)) ]), t._v(" "), "validate" === t.page ? n("span", {
                    staticClass: "sub-title__count",
                    attrs: {
                        eventid: "0"
                    },
                    on: {
                        tap: t.sendValidate
                    }
                }, [ t._v(t._s(t.count)) ]) : t._e() ]), t._v(" "), "login" === t.page ? n("div", {
                    staticClass: "input-area"
                }, [ n("input", {
                    directives: [ {
                        name: "model",
                        rawName: "v-model",
                        value: t.phoneNum,
                        expression: "phoneNum"
                    } ],
                    attrs: {
                        "placeholder-class": "placeholder-color",
                        type: "number",
                        placeholder: "请输入手机号",
                        maxlength: "11",
                        eventid: "1"
                    },
                    domProps: {
                        value: t.phoneNum
                    },
                    on: {
                        input: function(e) {
                            e.target.composing || (t.phoneNum = e.target.value);
                        }
                    }
                }) ]) : t._e(), t._v(" "), "validate" == t.page ? n("div", {
                    staticClass: "validate"
                }, [ n("div", {
                    staticClass: "validate-input clearfix"
                }, [ t._l(t.showValidateList, function(e, i) {
                    return n("span", {
                        key: e.id,
                        staticClass: "input-span",
                        class: {
                            active: e.id <= t.validate.length
                        }
                    }, [ t._v(t._s(e.number)) ]);
                }), t._v(" "), n("input", {
                    directives: [ {
                        name: "model",
                        rawName: "v-model",
                        value: t.validate,
                        expression: "validate"
                    } ],
                    staticClass: "input",
                    attrs: {
                        "placeholder-class": "input-ph",
                        type: "number",
                        focus: "validate" === t.page,
                        maxlength: "6",
                        eventid: "2"
                    },
                    domProps: {
                        value: t.validate
                    },
                    on: {
                        input: function(e) {
                            e.target.composing || (t.validate = e.target.value);
                        }
                    }
                }) ], 2) ]) : t._e(), t._v(" "), "login" === t.page ? n("div", {
                    staticClass: "btn-area"
                }, [ n("button", {
                    class: [ "xc-btn", "btn-large", "btn-primary", 11 !== t.phoneNum.length ? "disabled" : "" ],
                    attrs: {
                        "open-type": "getUserInfo",
                        disabled: 11 !== t.phoneNum.length || t.debounceFlag,
                        eventid: "3"
                    },
                    on: {
                        getuserinfo: t.bindGetUserInfo
                    }
                }, [ t._v("下一步") ]), t._v(" "), n("div", {
                    staticClass: "btn-area-hint"
                }, [ t._v("*该手机号尚未注册，将自动给您创建账号") ]) ], 1) : t._e() ]);
            },
            staticRenderFns: []
        };
        e.a = i;
    },
    "74pr": function(t, e, n) {
        var i = n("o4oM"), a = n("/nNs"), s = n("hHyJ")(i.a, a.a, function(t) {
            n("bi/f");
        }, null, null);
        e.a = s.exports;
    },
    Qza1: function(t, e, n) {
        Object.defineProperty(e, "__esModule", {
            value: !0
        });
        var i = n("74pr"), a = n("5nAL");
        new (n.n(a).a)(i.a).$mount(), e.default = {
            config: {
                navigationBarTitleText: "登录"
            }
        };
    },
    "bi/f": function(t, e) {},
    o4oM: function(t, e, n) {
        var i = n("Dd8w"), a = n.n(i), s = n("bWJ8"), o = n("E4LH"), u = n("khYN"), l = n("YaEn"), c = n("rG5b"), r = n("AbCI"), h = n("8xno"), d = n("oKD1");
        e.a = {
            data: function() {
                return {
                    ningTopRight: Object(d.a)("nb-youshang.png"),
                    ningBottomLeft: Object(d.a)("nb-zuoxia.png"),
                    phoneNum: "",
                    submitClick: !0,
                    url: "",
                    page: "login",
                    count: "重新获取",
                    timer: null,
                    validate: "",
                    focusFlag: !0,
                    showValidateList: [ {
                        id: 0,
                        number: ""
                    }, {
                        id: 1,
                        number: ""
                    }, {
                        id: 2,
                        number: ""
                    }, {
                        id: 3,
                        number: ""
                    }, {
                        id: 4,
                        number: ""
                    }, {
                        id: 5,
                        number: ""
                    } ],
                    isNewUser: "",
                    debounceFlag: !1,
                    title: {
                        wuTaiShanHome: this.$store.state.wechatParam.name.includes("wts-youyong") ? "五台山游泳馆欢迎您！" : "五台山健身会馆欢迎您！",
                        ningboHome: this.$store.state.wechatParam.name.includes("yuti") ? "体育重庆在线惠民服务平台欢迎您！" : this.$store.state.wechatParam.name.includes("chuanyutong") ? "川渝体育通欢迎您" : "宁波市体育局欢迎您！"
                    },
                    welcomeTitle: {
                        wuTaiShanHome: "赶快登录注册，开始锻炼吧！"
                    }
                };
            },
            components: {
                "xc-button": s.a
            },
            computed: {
                isAuthed: function() {
                    return this.$store.state.isAuthed;
                },
                appName: function() {
                    return this.$store.state.wechatParam.name;
                }
            },
            mixins: [ h.a ],
            watch: {
                validate: function(t) {
                    this.getInputBox(), 6 === t.length && this.submit();
                }
            },
            onLoad: function() {
                this.page = "login", this.phoneNum = "", this.debounceFlag = !1;
            },
            methods: {
                deletePhone: function() {
                    this.phoneNum = "";
                },
                bindGetUserInfo: function(t) {
                    this.debounceFlag = !0, Object(r.b)(t, this.loginSubmit.bind(this));
                },
                loginSubmit: function() {
                    var t = this;
                    this.$store.state.loginInfo.openId && this.submitClick && 11 === this.phoneNum.length && (this.submitClick = !1, 
                    Object(o.c)(this.phoneNum) ? (this.submitClick = !0, this.page = "validate", this.validateOnLoad()) : Object(u.t)({
                        title: "请输入正确的手机号！"
                    }).then(function() {
                        t.submitClick = !0;
                    }));
                },
                validateOnLoad: function() {
                    this.validate = "", this.count = "重新获取", clearTimeout(this.timer), this.timer = null, 
                    this.sendValidate(), this.getInputBox();
                },
                goLogin: function() {
                    this.page = "login";
                },
                sendValidate: function() {
                    var t = this;
                    this.timer || c.B.sendLoginVerifyCode(this.phoneNum).then(function(e) {
                        t.isNewUser = e.isNewUser, t.getTime();
                    });
                },
                getTime: function() {
                    var t = this, e = 60;
                    this.count = e + "s", this.timer = setInterval(function() {
                        e > 0 && e <= 60 ? (e--, t.count = e + "s") : (clearInterval(t.timer), t.timer = null, 
                        t.count = "重新获取");
                    }, 1e3);
                },
                getInputBox: function() {
                    var t = this;
                    this.showValidateList.forEach(function(e) {
                        e.id < t.validate.length ? e.number = t.validate[e.id] : e.id === t.validate.length ? e.number = "|" : e.number = "";
                    });
                },
                loginSuccess: function(t) {
                    var e = this;
                    this.$store.dispatch({
                        type: "setNetUserId",
                        netUserId: t
                    }), this.$store.dispatch({
                        type: "setUserPhoneNum",
                        phoneNum: this.phoneNum
                    }), Object(u.p)("netUserId", t), Object(u.p)("phoneNum", this.phoneNum);
                    var n = "0" === this.isNewUser ? "登录成功！" : "注册成功！";
                    this.isNingbo && c.L.findVerifyInfo().then(function(t) {
                        Object(u.q)("couponAuthInfo", t);
                    }), Object(u.t)({
                        title: n,
                        duration: 1e3
                    }).then(function() {
                        if (e.url && "community" === e.url) l.a.go({
                            key: e.url,
                            type: "reLaunch"
                        }); else if (e.url) {
                            var t = e.$root.$mp.query;
                            l.a.go({
                                key: e.url,
                                type: "redirectTo",
                                params: t
                            });
                        } else Object(u.h)({
                            delta: 1
                        });
                    });
                },
                submit: function() {
                    var t = this;
                    c.B.bind({
                        phoneNum: this.phoneNum,
                        code: this.validate
                    }).then(function(e) {
                        t.$store.dispatch({
                            type: "setLoginInfo",
                            loginInfo: a()({}, t.$store.state.loginInfo, {
                                accessToken: e.netUser.accessToken,
                                accountId: e.netUser.coAccountId,
                                coAppId: e.netUser.coAppId
                            })
                        }), t.loginSuccess(e.netUserId);
                    }).catch(function(e) {
                        1101 === e.error ? Object(u.s)({
                            content: "验证码错误，请重试！",
                            showCancel: !1,
                            success: function(e) {
                                e.confirm && (t.validate = "", t.getInputBox());
                            }
                        }) : 1001 === e.error ? t.loginSuccess(e.netUserId) : (Object(u.t)({
                            title: e.message || e.error + ",message 为 null"
                        }), t.validate = "", t.getInputBox());
                    });
                }
            }
        };
    }
}, [ "Qza1" ]);